Sample Payload
The following sample gets the supporting information comments for a work request with the GUID = 54e43a5a-7da4-e611-946c-06edd62954d6 :
https://mysite.assetic.net/api/v2/workrequest/54e43a5a-7da4-e611-946c-06edd62954d6/supportinginfo
The 'Supporting Information' field in a Work Request is used to record free text comments such as those provided by the person lodging the request, or by staff that are responding to the request. The following Assetic REST API endpoints can be used to add additional comments to a request, or retrieve the comments as an array:
GET /api/v2/workrequest/{id}/supportinginfo
POST /api/v2/workrequest/{id}/supportinginfo
In the above endpoints {id} is the Assetic Work Request unique GUID identifier. The user friendly Work Request ID cannot be used.
To create a comment the Assetic REST API endpoint POST /api/v2/workrequest/{id}/supportinginfo is used.
The following is a list of the fields that can be used when creating a comment for a work request:
Field | Description | Type | Mandatory |
Description | The comment to add to the work request. 4000 character limit | String | Yes |
CreatedDateTime | The datetime of the comment. This allows the comment timestamp to reflect the time it was received, rather than the time it was integrated. If NULL then timestamp at time of integration is applied. | Datetime | No |
The following payload adds a comment to an existing work request:
{ "Description": "Drain remains blocked", "CreatedDateTime": "2017-05-28T23:04:20.122Z" }
To get a list of comments against a work request the Assetic REST API endpoint GET /api/v2/workrequest/{id}/supportinginfo is used.
This API response has the following properties:
Field | Description | Data Type |
TotalResults | Total number of supporting information comments | integer |
TotalPages | Number of pages in the response | integer |
Page | Page number of the response | integer |
ResourceList | The supporting information comments including comment date and display name of the user that created the comment. | array of supporting information object |
The supporting information object (in the 'ResourceList' array) has the following fields:
Field | Description | Data Type |
Id | Unique GUID of the comment | GUID |
Description | The supporting information history comment | String |
CreatedBy | The unique GUID of the user that created the comment | GUID |
CreatedByDisplayName | The name of the user that created the comment | String |
CreatedDateTime | User definable date and time. This allows the time the comment was added to an external application to be used to define the comment creation time. It is this timestamp that is presented in the Assetic UI | Datetime |
SystemAddedTime | The date and time the comment was created in Assetic. This is not visible in the Assetic UI | Datetime |
Sample Payload
The following sample gets the supporting information comments for a work request with the GUID = 54e43a5a-7da4-e611-946c-06edd62954d6 :
https://mysite.assetic.net/api/v2/workrequest/54e43a5a-7da4-e611-946c-06edd62954d6/supportinginfo
Thanks for taking the time to give us some feedback.